package com.cgbl.cg.view

import android.content.Context
import androidx.recyclerview.widget.LinearLayoutManager
import androidx.recyclerview.widget.RecyclerView
import com.lxj.xpopup.core.BottomPopupView
import com.cgbl.cg.R
import com.cgbl.cg.adapter.JobAdapter

class UpdateJobPop(context: Context) : BottomPopupView(context) {

    lateinit var jobList: RecyclerView

    lateinit var jobAdapter: JobAdapter

    override fun getImplLayoutId(): Int {
        return R.layout.app_pop_update_job
    }

    override fun initPopupContent() {
        super.initPopupContent()
        jobList = findViewById(R.id.job_list)
        jobAdapter = JobAdapter()
        jobList.layoutManager = LinearLayoutManager(context)
        jobList.adapter = jobAdapter

        val job = mutableListOf(
            "平面设计师", "插画师", "三维设计师", "网页设计师", "UI设计师", "Unity工程师", "CG动画师",
            "UX设计师", "产品设计师", "动画师", "室内设计师", "资深游戏美术师", "教育工作者", "学生"
        )

        jobAdapter.setNewInstance(job)
    }
}